package com.example;

/**
 * Created by zengliang on 17/7/3.
 */

public class FloatTest {

    public static void main(String[] args) throws Exception {

        int price = 1380;
        int actualPrice = 1228;

        int discount = (int) Math.round((double) actualPrice / price * 100);
        System.out.println(discount);
    }
}
